<!DOCTYPE html>
<html>
  <head>
    <meta charset="UTF-8">
    <title>{{ form.pagename }} - 学校宝典</title>
    <meta content='width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no' name='viewport'>
    <!-- Bootstrap 3.3.4 -->
    <link href="/bd/web/AdminLTE/bootstrap/css/bootstrap.min.css" rel="stylesheet" type="text/css" />    
    <!-- FontAwesome 4.3.0 -->
    <link href="/bd/web/static/font-awesome.min.css" rel="stylesheet" type="text/css" />
    <!-- Ionicons 2.0.0 -->
    <link href="/bd/web/static/ionicons.min.css" rel="stylesheet" type="text/css" />    
    <!-- Theme style -->
    <link href="/bd/web/AdminLTE/dist/css/AdminLTE.min.css" rel="stylesheet" type="text/css" />
    <!-- AdminLTE Skins. Choose a skin from the css/skins 
         folder instead of downloading all of them to reduce the load. -->
    <link href="/bd/web/AdminLTE/dist/css/skins/_all-skins.min.css" rel="stylesheet" type="text/css" />
    <!-- iCheck -->
    <link href="/bd/web/AdminLTE/plugins/iCheck/flat/blue.css" rel="stylesheet" type="text/css" />
    <!-- Morris chart -->
    <link href="/bd/web/AdminLTE/plugins/morris/morris.css" rel="stylesheet" type="text/css" />
    <!-- jvectormap -->
    <link href="/bd/web/AdminLTE/plugins/jvectormap/jquery-jvectormap-1.2.2.css" rel="stylesheet" type="text/css" />
    <!-- Date Picker -->
    <link href="/bd/web/AdminLTE/plugins/datepicker/datepicker3.css" rel="stylesheet" type="text/css" />
    <!-- Daterange picker -->
    <link href="/bd/web/AdminLTE/plugins/daterangepicker/daterangepicker-bs3.css" rel="stylesheet" type="text/css" />
    <!-- bootstrap wysihtml5 - text editor -->
    <link href="/bd/web/AdminLTE/plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.min.css" rel="stylesheet" type="text/css" />
    <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
    <!--[if lt IE 9]>
        <script src="/bd/web/static/html5shiv.min.js"></script>
        <script src="/bd/web/static/respond.min.js"></script>
    <![endif]-->

<link rel="stylesheet" href="/bd/web/plugins/Font-Awesome-3.2.1/css/font-awesome.min.css" />
        <script src="/bd/web/static/base.js"></script>
  </head>

  <body class="skin-blue sidebar-mini">
    <div class="wrapper">
      <!-- header -->
      <header class="main-header">
        <!-- Logo -->
        <a href="/index.html" class="logo">
          <!-- mini logo for sidebar mini 50x50 pixels -->
          <span class="logo-mini"><b>宝典</b></span>
          <!-- logo for regular state and mobile devices -->
          <span class="logo-lg"><b>学校宝典</b></span>
        </a>
        <!-- Header Navbar: style can be found in header.less -->
        <nav class="navbar navbar-static-top" role="navigation">
          <!-- Sidebar toggle button-->
          <a href="#" class="sidebar-toggle" data-toggle="offcanvas" role="button">
            <span class="sr-only">Toggle navigation</span>
	    <span class="icon-bar"></span>
	    <span class="icon-bar"></span>
	    <span class="icon-bar"></span>
          </a>
          <div class="navbar-custom-menu">
            <ul class="nav navbar-nav">
              	      
              <!-- User Account: style can be found in dropdown.less -->
	      <!-- user account photo view -->
              <li class="dropdown user user-menu">
                <a href="#" class="dropdown-toggle" data-toggle="dropdown">
                  <img src="/bd/web/AdminLTE/dist/img/user2-160x160.jpg" class="user-image" alt="User Image"/>
                  <span class="hidden-xs">管理员</span>
                </a>
                <ul class="dropdown-menu">
                  <!-- User image -->
                  <li class="user-header">
                    <img src="/bd/web/AdminLTE/dist/img/user2-160x160.jpg" class="img-circle" alt="User Image" />
                    <p>
                      管理员
                      <small>2015年</small>
                    </p>
                  </li>
                  <!-- Menu Body -->
                  <li class="user-body">
                    <div class="col-xs-4 text-center">
                      <a href="#">工作1</a>
                    </div>
                    <div class="col-xs-4 text-center">
                      <a href="#">工作2</a>
                    </div>
                    <div class="col-xs-4 text-center">
                      <a href="#">工作3</a>
                    </div>
                  </li>
                  <!-- Menu Footer-->
                  <li class="user-footer">
                    <div class="pull-left">
                      <a href="#" class="btn btn-default btn-flat">个人信息</a>
                    </div>
                    <div class="pull-right">
                      <a href="#" class="btn btn-default btn-flat">签出</a>
                    </div>
                  </li>
                </ul>
              </li>
	      <!-- }}} -->


            </ul>
          </div>
        </nav>
      </header>
      <!-- }}} -->

      <!-- Left side column. contains the logo and sidebar -->
      {# <!-- {{{ --> #}
      <aside class="main-sidebar">
        <!-- sidebar: style can be found in sidebar.less -->
	{# <!-- {{{ --> #}
        <section class="sidebar">
          <!-- Sidebar user panel -->
	  {# <!-- {{{ --> #}
          <div class="user-panel">
            <div class="pull-left image">
              <img src="/bd/web/AdminLTE/dist/img/user2-160x160.jpg" class="img-circle" alt="User Image" />
            </div>
            <div class="pull-left info">
              <p>管理员</p>

              <a href="#"><i class="fa fa-circle text-success"></i> 在线</a>
            </div>
          </div>
	  <!-- }}} -->

	  <!-- search form in left side column -->
	  {# <!-- {{{ --> #}
          <!-- search form -->
          <form action="#" method="get" class="sidebar-form">
            <div class="input-group">
              <input type="text" name="q" class="form-control" placeholder="搜索..."/>
              <span class="input-group-btn">
                <button type='submit' name='search' id='search-btn' class="btn btn-flat"><i class="fa fa-search"></i></button>
              </span>
            </div>
          </form>
          <!-- /.search form -->
	  <!-- }}} -->

          <!-- sidebar menu: : style can be found in sidebar.less -->
          <ul class="sidebar-menu">
            <li class="header">导航</li>
	    <li class="active"><a href="/bd/view_schools"><i class="fa fa-circle-o"></i> 所有学校 
		{% if form and form.school_count %}
               <small class="label pull-right bg-yellow">{{form.school_count}}</small>
	       {%  endif %}
</a></li>
	    <li class="active"><a href="/bd/view_institutions"><i class="fa fa-circle-o"></i> 所有培训机构
		{% if form and form.institution_count %}
               <small class="label pull-right bg-yellow">{{form.institution_count}}</small>
	       {%  endif %}
</a></li>
	    <li class="active"><a href="/bd/view_bulletins"><i class="fa fa-circle-o"></i> 公告列表
		{% if form and form.bulletin_count %}
               <small class="label pull-right bg-yellow">{{form.bulletin_count}}</small>
	       {%  endif %}
</a></li>
	    <li class="active"><a href="/bd/view_accounts"><i class="fa fa-circle-o"></i> 用户帐号列表
		{% if form and form.account_count %}
               <small class="label pull-right bg-yellow">{{form.account_count}}</small>
	       {%  endif %}
</a></li>
	    <li class="header">编辑</li>
	    <li class="active"><a href="/bd/view_school"><i class="fa fa-circle-o"></i> 新建学校</a></li>
	    <li class="active"><a href="/bd/view_institution"><i class="fa fa-circle-o"></i> 新建培训机构</a></li>
	    <li class="active"><a href="/bd/view_bulletin"><i class="fa fa-circle-o"></i> 新建公告</a></li>
	    <li class="active"><a href="/bd/view_account"><i class="fa fa-circle-o"></i> 新建用户帐号</a></li>

	    <li class="header">其他</li>
            <li><a href="#"><i class="fa fa-circle-o text-red"></i> <span>工作1</span></a></li>
            <li><a href="#"><i class="fa fa-circle-o text-yellow"></i> <span>工作2</span></a></li>
            <li><a href="#"><i class="fa fa-circle-o text-aqua"></i> <span>工作3</span></a></li>
          </ul>
        </section>
        <!-- /.sidebar -->
	<!-- }}} -->
      </aside>
      <!-- }}} -->

      <!-- Content Wrapper. Contains page content -->
      {# <!-- {{{ --> #}
      <div class="content-wrapper">
        <!-- Content Header (Page header) -->
	{# <!-- {{{ --> #}
        <section class="content-header">
          <h1>
            {{form.pagename}}
            <small>{{form.pagetask}}</small>
          </h1>
          <ol class="breadcrumb">
            <li><a href="#"><i class="fa fa-dashboard"></i> 主页</a></li>
            <li class="active">{{form.pagename}}</li>
          </ol>
        </section>
	<!-- }}} -->






        <!-- Main content -->
        <section class="content">

{% macro render_field(field) %}
  {{ field.label }} <br>
  {{ field(**kwargs)|safe }}
  {% if field.errors %}
    <ul class=errors style="color:red;">
    {% for error in field.errors %}
      <li >{{ error }}</li>
    {% endfor %}
    </ul>
  {% endif %}
  
{% endmacro %}

        {% block content %}{% endblock %}
        </section><!-- /.content -->
      </div><!-- /.content-wrapper -->
      <!-- }}} -->

      <!-- footer -->
      {# <!-- {{{ --> #}
      <footer class="main-footer">
        <div class="pull-right hidden-xs">
          <b>Version</b> 1.0
        </div>
        <strong>Copyright &copy; 2015 <a href="http://totalsolution.com"></a>.</strong> All rights reserved.
      </footer>
      <!-- }}} -->


      
      <!-- Add the sidebar's background. This div must be placed
           immediately after the control sidebar -->
      <div class='control-sidebar-bg'></div>
      <!-- }}} -->
    </div><!-- ./wrapper -->

    <!-- jQuery 2.1.4 -->
    <script src="/bd/web/AdminLTE/plugins/jQuery/jQuery-2.1.4.min.js"></script>
    <!-- jQuery UI 1.11.2 -->
    <script src="/bd/web/static/jquery-ui.min.js" type="text/javascript"></script>
    <!-- Resolve conflict in jQuery UI tooltip with Bootstrap tooltip -->

    <!-- Bootstrap 3.3.2 JS -->
    <script src="/bd/web/AdminLTE/bootstrap/js/bootstrap.min.js" type="text/javascript"></script>    
    <!-- Morris.js charts -->
    <script src="/bd/web/static/raphael-min.js"></script>
    <script src="/bd/web/AdminLTE/plugins/morris/morris.min.js" type="text/javascript"></script>
    <!-- Sparkline -->
    <script src="/bd/web/AdminLTE/plugins/sparkline/jquery.sparkline.min.js" type="text/javascript"></script>
    <!-- jvectormap -->
    <script src="/bd/web/AdminLTE/plugins/jvectormap/jquery-jvectormap-1.2.2.min.js" type="text/javascript"></script>
    <script src="/bd/web/AdminLTE/plugins/jvectormap/jquery-jvectormap-world-mill-en.js" type="text/javascript"></script>
    <!-- jQuery Knob Chart -->
    <script src="/bd/web/AdminLTE/plugins/knob/jquery.knob.js" type="text/javascript"></script>
    <!-- daterangepicker -->
    <script src="/bd/web/static/moment.min.js" type="text/javascript"></script>
    <script src="/bd/web/AdminLTE/plugins/daterangepicker/daterangepicker.js" type="text/javascript"></script>
    <!-- datepicker -->
    <script src="/bd/web/AdminLTE/plugins/datepicker/bootstrap-datepicker.js" type="text/javascript"></script>
    <!-- Bootstrap WYSIHTML5 -->
    <script src="/bd/web/AdminLTE/plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.all.min.js" type="text/javascript"></script>
    <!-- Slimscroll -->
    <script src="/bd/web/AdminLTE/plugins/slimScroll/jquery.slimscroll.min.js" type="text/javascript"></script>
    <!-- FastClick -->
    <script src="/bd/web/AdminLTE/plugins/fastclick/fastclick.min.js"></script>
    <!-- AdminLTE App -->
    <script src="/bd/web/AdminLTE/dist/js/app.min.js" type="text/javascript"></script>    
    

    <!-- AdminLTE for demo purposes -->
    <script src="../../dist/js/demo.js" type="text/javascript"></script>

  </body>
</html>
